{extend name="public/father" /}


{block name='main'}

<div class="layui-card">
	<div class="layui-card-body">

		<form class="layui-form" method="post">

			<div class="layui-form-item">
				<label class="layui-form-label">配置分组</label>
				<div class="layui-input-block">
					<select name="group" lay-verify="required">

						{foreach $system_config as $k=>$v}
						<option value="{$k}" {:input('param.group')==$k ? ' selected' : ''}>{$v} [{$k}]</option>
						{/foreach}

					</select>
				</div>
			</div>

			<div class="layui-form-item">
				<label class="layui-form-label">排序</label>
				<div class="layui-input-block">
					<input type="text" name="sort" value="500" required lay-verify="number" autocomplete="off" class="layui-input">
				</div>
			</div>

			<div class="layui-form-item">
				<label class="layui-form-label">配置标题</label>
				<div class="layui-input-block">
					<input type="text" name="title" required lay-verify="required" autocomplete="off" class="layui-input">
				</div>
			</div>

			<div class="layui-form-item">
				<label class="layui-form-label">配置名称</label>
				<div class="layui-input-block">
					<input type="text" name="name" required lay-verify="required" placeholder="由英文字母和下划线组成" autocomplete="off" class="layui-input">
				</div>
			</div>

			<div class="layui-form-item">
				<label class="layui-form-label">配置类型</label>
				<div class="layui-input-block">
					<select name="type" lay-verify="required">
						<option value="input">单行文本 [input]</option>
						<option value="textarea">多行文本 [textarea]</option>
<!--						<option value="switch">[switch]开关</option>-->
<!--						<option value="radio">[radio]单选按钮</option>-->
<!--						<option value="checkbox">[checkbox]多选框</option>-->
						<option value="select">下拉框 [select]</option>
						<option value="image">图片 [image]</option>
<!--						<option value="file">[file]文件</option>-->

						<!--<option value="tags">[tags]标签</option>-->
						<!--<option value="hidden">[hidden]隐藏</option>-->
<!--						<option value="array">[array]数组</option>-->

						<!--<option value="datetime">[datetime]日期+时间</option>-->
						<!--<option value="date">[date]日期</option>-->
						<!--<option value="time">[time]时间</option>-->
					</select>
				</div>
			</div>

			<div class="layui-form-item">
				<label class="layui-form-label">配置默认值</label>
				<div class="layui-input-block">
					<textarea name="value" placeholder="配置类型为数组时请按如下格式填写：
值|值|值" class="layui-textarea"></textarea>
				</div>
			</div>

			<div class="layui-form-item">
				<label class="layui-form-label">配置选项</label>
				<div class="layui-input-block">
					<textarea name="options" placeholder="仅适用类型：下拉框，格式：
选项值:选项名
选项值:选项名
1:北京
2:上海" class="layui-textarea"></textarea>
				</div>
			</div>

			<div class="layui-form-item">
				<label class="layui-form-label">配置提示</label>
				<div class="layui-input-block">
					<textarea name="tips" placeholder="[选填，支持HTML]" class="layui-textarea"></textarea>
				</div>
			</div>

			<div class="layui-form-item">
				<label class="layui-form-label">状态</label>
				<div class="layui-input-block">
					<input type="checkbox" name="status" value="1" lay-skin="switch" lay-text="启用|禁用" checked>
				</div>
			</div>

			<div class="layui-form-item">
				<div class="layui-input-block">
					<button class="layui-btn" lay-submit lay-filter="create">立即提交</button>
				</div>
			</div>
		</form>

	</div>
</div>

{/block}
